import http from '@/utils/request'

class PostServiceTemp {


	usePostApi(id: Number) {
		return http.get('/sys/post/' + id)
	}

	usePostSubmitApi(dataForm: any) {
		if (dataForm.id) {
			return http.put('/sys/post', dataForm)
		} else {
			return http.post('/sys/post', dataForm)
		}
	}

	usePostListApi() {
		return http.get('/sys/post/list')
	}
}

const PostService = new PostServiceTemp();
export {
	PostService
}
